package cn.ztf.zshop.security.admin.utils;

import cn.ztf.zshop.security.admin.bo.AdminInfoInTokenBO;
import com.alibaba.ttl.TransmittableThreadLocal;

public class AdminContext {

    private static final ThreadLocal<AdminInfoInTokenBO> USER_INFO_IN_TOKEN_HOLDER = new TransmittableThreadLocal<>();


    public static AdminInfoInTokenBO get(){
        return USER_INFO_IN_TOKEN_HOLDER.get();
    }

    public static void remove(){
        USER_INFO_IN_TOKEN_HOLDER.remove();
    }

}
